<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>事件</title>
</head>
<body>
	<script>
		var ani = {
			weight : '50kg',
			age : '5岁',
			variety : '雪纳瑞',
			eat : function(){
				alert('等一下，我在吃东西呢！');
			},
			sleep : function(){
				alert('等一下，我还要再睡一会！');
			},
			play : function(){
				alert('我再玩一会！');
			},
			shuxing :function(){
				document.write('体重：' + this.weight  + '年龄：' +  this.age  + '品种：' +  this.variety)
			}
		}
		
	</script>
	    <button >吃</button>
		<button ondblclick="ani.sleep()";onclick="ani.eat()">睡</button>
		<button onclick="ani.play()">玩</button>
		<button onclick="ani.shuxing()">查看所有动物的属性</button>
</body>
</html>